package com.heaven.customerServer.customerController.vo.uploadFile;

import jakarta.validation.constraints.Max;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;
import org.springframework.http.codec.multipart.FilePart;

@Data
public class FileFeatureReq {
    @NotBlank(message = "MD5值不能为空")
    private String md5;

    @NotBlank(message = "文件名不能为空")
    private String fileName;

    /** 大文件大小 单位：B */
    @NotNull(message = "文件大小值必须携带")
    @Max(value = 1024 * 1024 * 50, message = "文件大小不能超过50MB")
    private Long size;

    /** 分块文件流 */
    @NotNull(message = "文件流不能为空")
    private FilePart file;
}
